!!! html
%html
  %head
    %title Depot
    = stylesheet_link_tag    "application", media: "all", "data-turbolinks-track" => true
    = javascript_include_tag "application", "data-turbolinks-track" => true
    = csrf_meta_tags

  %body{class: controller.controller_name}
    #banner 
      = form_tag store_path,class:'locale' do
        = select_tag 'set_locale',options_for_select(LANGUAGES,I18n.locale.to_s),onchange: 'this.form.submit()'
        = submit_tag 'submit'
        = javascript_tag "$('.locale input').hide()"
      = image_tag('logo.png')
      = @page_title || t('.title')
    #columns
      #side
        - if @cart
          = hidden_div_if(@cart.line_items.empty?, id: 'cart') do
            = render @cart
        %p.time= Time.now.strftime('%B %d, %Y %I:%M:%S%p')
        %ul
          %li= link_to t('.home'), "#"
          %li= link_to t('.questions'), "#questions"
          %li= link_to t('.news'), "#news"
          %li= link_to t('.contact'), "#contact"
        - if session[:user_id]
          %ul
            %li= link_to 'Orders', orders_path
            %li= link_to 'Products',products_path
            %li= link_to 'Users',users_path
          = button_to 'Logout',logout_path,method: :delete   
      #main
        = yield